package com.chancingpack.dal.dao.mybatis;

import com.chancingpack.dal.dao.ReceiptEvaluateDao;
import com.chancingpack.dal.model.WxReceiptEvaluate;
import com.chancingpack.dal.service.WxReceiptEvaluateMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

/**
 * Created by lenovo on 2017/7/18.
 */
@Repository
public class ReceiptEvaluateDaoImpl implements ReceiptEvaluateDao {

    @Autowired
    private WxReceiptEvaluateMapper wxReceiptEvaluateMapper;

    /**
     * 录入收货及时率信息数据
     * @param wxReceiptEvaluate
     * @return
     */
    public boolean insertReceiptEvaluate(WxReceiptEvaluate wxReceiptEvaluate) {
        return wxReceiptEvaluateMapper.insertSelective(wxReceiptEvaluate) > 0;
    }

    public List<Map<String, Object>> selectcustName() {
        return wxReceiptEvaluateMapper.selectcustName();
    }

    public List<Map<String,Object>> selectBydetailId(Map<String,Object> map) {
        return wxReceiptEvaluateMapper.selectBydetailId(map);
    }

    public List<Map<String, Object>> selectDetailIdByCustId(String custId) {
        return wxReceiptEvaluateMapper.selectDetailIdByCustId(custId);
    }

    public List<Map<String,Object>> selectReceiptEvaluate(Integer detailId) {
        return wxReceiptEvaluateMapper.selectReceiptEvaluate(detailId);
    }

    public List<Map<String, Object>> selectReceiveMessagepage(Map<String, Object> map) {
        return wxReceiptEvaluateMapper.selectReceiveMessagepage(map);
    }

    public int selectCount(Map<String, Object> map) {
        return wxReceiptEvaluateMapper.selectCount(map);
    }
}
